package com.ctg.behavior.common.userslist.upper;

import java.util.ArrayList;
import java.util.List;

import com.ctg.behavior.common.calc.CtCalcFilter;
import com.ctg.behavior.common.funnel.CtFunnelDetailBody;

import lombok.Data;

@Data
public class CtUpperFunnelBody {

//	/*
//	 {
//	"fromDate": "2021-05-31",
//	"toDate": "2021-06-04",
//	"extendOverEndDate": "true",
//	"config": {
//		"measures": [
//			"conversion_rate"
//		],
//		"groups": [
//			"0",
//			"1"
//		],
//		"step": "_ALL",
//		"type": "percent"
//	},
//	"state": "overview",
//	"completeStepRows": "true",
//	"funnelId": "71",
//	"samplingFactor": "64",
//	"byFields": [
//		"event.commodityDetail._lib"
//	],
//	"byFieldSteps": [
//		"0"
//	],
//	"sliceEndDate": "",
//	"sliceStep": "0",
//	"sliceWastageUser": "false",
//	"detail": "true",
//	"sliceByValues": [
//		"Android"
//	]
//}
//	 */
	
	private String fromDate;
	private String toDate;
	private String extendOverEndDate = "true";
	private Config config = new Config();
	private String state;
	private String completeStepRows = "true";
	private String funnelId;
	private String samplingFactor = "64";
	private List<String> byFields = new ArrayList<>();
	private List<String> byFieldSteps = new ArrayList<>();
	private String sliceEndDate;
	private String sliceStep;
	private String sliceWastageUser = "false";
	private String detail = "true";
	private List<String> sliceByValues = new ArrayList<>();
	// 筛选条件，可用于用户属性 或 事件属性筛选
	private CtCalcFilter filter = new CtCalcFilter();
	
	// 漏斗步骤详情
	private CtFunnelDetailBody funnelBody = new CtFunnelDetailBody();
	
	@Data
	public static class Config {
		
		public List<String> measures = new ArrayList<>();
		public List<String> groups = new ArrayList<>();
		public String step;
		public String type = "percent";

	}
	
}
